package org.dtrd.modules.faq.entity.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.dtrd.modules.faq.entity.po.DtrdExtEmsYwFaqs;

/**
 * <p>
 * 知识问答
 * </p>
 *
 * @author QR
 * @since 2021-12-06
 */
@Getter
@Setter
@ApiModel(value = "DtrdExtEmsYwFaqs数据传输对象", description = "知识问答")
public class FaqDetail {

    private Integer dataId;


    @ApiModelProperty("常见问题")
    private String faqQuestion;

    @ApiModelProperty("问题答案")
    private String faqAnswer;

    @ApiModelProperty("所属分类")
    private Integer faqCategoryid;

    @ApiModelProperty("常见问题标签")
    private String faqTips;

    @ApiModelProperty("常见问题URL")
    private String faqUrl;

    private String faqThumb;

    @ApiModelProperty("浏览量")
    private Integer faqViews;

    public FaqDetail parseFromPo(DtrdExtEmsYwFaqs po) {
        dataId = po.getDataId();
        faqQuestion = po.getFaqQuestion();
        faqAnswer = po.getFaqAnswer();
        faqCategoryid = po.getFaqCategoryid();
        faqTips = po.getFaqTips();
        faqUrl = po.getFaqUrl();
        faqThumb = po.getFaqThumb();
        faqViews = po.getFaqViews();
        return this;
    }
}
